DOCKER_VER=220427
DOCKER_NAME=neutron-probe

docker:
	DOCKER_BUILDKIT=0 docker build --tag=chenjingdong/$(DOCKER_NAME):$(DOCKER_VER) -f docker/Dockerfile .

docker-no-cache:
	DOCKER_BUILDKIT=0 docker build --tag=chenjingdong/$(DOCKER_NAME):$(DOCKER_VER) --no-cache -f docker/Dockerfile .

clean:
	docker-compose -f docker/docker-compose.yml down --rmi all -v --remove-orphans

dev:
	docker run -it --rm -p 8888:8887 chenjingdong/$(DOCKER_NAME):$(DOCKER_VER) /bin/sh

save:
	mkdir -p ../../docker-tars
	docker save -o ../../docker-tars/$(DOCKER_NAME).tar chenjingdong/$(DOCKER_NAME):$(DOCKER_VER)

.PHONY: all docker dev stop release clean docker-dev docker sftp everything docker-no-cache

everything: docker save sftp
